<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib prefix="spring" 	uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="tiles" 	uri="http://tiles.apache.org/tags-tiles" %>
<%@ taglib prefix="c"		uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="form" 	uri="http://www.springframework.org/tags/form" %>
<%@ page contentType="text/html; charset=utf-8" %>
<%@ page language="java" pageEncoding="utf-8"%>

<script type="text/javascript">
$(document).ready(function(){
	setMenuSelection("adauga");
	
    $("#tabPartenerCard").kendoTabStrip({
        animation:  {
            open: {
                effects: "fadeIn"
            }
        }
    });	  
    
    $("#pStatus").kendoDropDownList();
    
    pUpdatedDate
    
    $("#btPartenerList").kendoButton({
        icon: "funnel"
    });

    $("#btPartenerCard").kendoButton({
        icon: "plus"
    });
    
    $("#btPartenerCardSubmit").kendoButton({
        icon: "tick"
    });

    $("#btPartenerCardReset").kendoButton({
        icon: "cancel"
    });
    
    $("#btPartenerCardApply").kendoButton({
        icon: "custom"
    });
    
});


function SubmitFormPartenerCard(pPostOperation){
	var formAction = $("#formPartenerCard").attr( 'action' );
	$("#formPartenerCard").attr('action', formAction + '?pPostOperation='+pPostOperation);
	$("#formPartenerCard").submit();
}


</script>

<CENTER>
<p style="text-align: left;">
	<button id="btPartenerList" type="button" onclick="javascript:window.open('vizualizeazaPartener', 	target='_self')";>	Lista parteneri</button>
	<button id="btPartenerCard" type="button" onclick="javascript:window.open('adaugaPartener', 		target='_self')";>	Adaugă partener</button>
	<c:if test="${errorMessage != '' &&  errorMessage != '0'}">
		<span id="errorMessage" class="errorMessage"> ${errorMessage} </span>
	</c:if>
	
</p>
<form:form id="formPartenerCard" method="post" commandName="partenerItem" action="adaugaPartener">
<div id="tabPartenerCard" style="text-align: left;" >
	<ul>
	    <li class="k-state-active">
	              Partener - Date generale
	    </li>
	</ul> 
	<div>
		
		<div class="k-block k-shadow">
			<ul class="forms" style="font-size: 14px;">
				<form:hidden id="pId" path="id" name="id"/>
					<li>							  
						<label  for="pMdValue" class="required">Denumirea Ro:  </label>
						<form:input type="text" id="pMdValue" 	path="mdValue"  	name="mdValue" style="width:250px;"  class="k-textbox"  required="true"/> 
					</li>
					<li>							  
						<label  for="pRuValue" class="required">Denumirea Ru:  </label>
						<form:input type="text" id="pRuValue" 	path="ruValue"  	name="ruValue" style="width:250px;"  class="k-textbox"  required="true"/> 
					</li>
					<li>							  
						<label  for="pEnValue" class="required">Denumirea En:  </label>
						<form:input type="text" id="pEnValue" 	path="enValue"  	name="enValue" style="width:250px;"  class="k-textbox"  required="true"/> 
					</li>												
					<li>
						<label  for="pStatus" class="required">Statut:  </label>
						<form:select id="pStatus" path="status" name="status" style="width:200px;" >
							<option 	 value="" 		label=" - Selectati - " ></option>
							<form:option value="1" 		label="Activ">					</form:option>
						 	<form:option value="0" 		label="Deactivat">				</form:option> 
	   					</form:select>	
					
					</li>
					<li>							
						<label  for="pUpdatedDate" >Data ultimii modificari:  </label> 						
						<form:input type="text" id="pUpdatedDate" 	path="updatedDate"  name="updatedDate" 	style="width:120px;"  class="k-textbox"  disabled="true" ></form:input> 
				</li>    					
			</ul>	
		</div>
	</div>
</div>
<p style="text-align: right;">
	<button id="btPartenerCardApply"		type="button" onclick="SubmitFormPartenerCard('remain')" 	>Aplică</button>
	<button id="btPartenerCardSubmit" 		type="button" onclick="SubmitFormPartenerCard('close')"  >Salvează</button>
	<button id="btPartenerCardReset" 		type="reset"  onclick="javascript: window.history.back();">Anulează</button>
</p> 		
</form:form> 
    
</CENTER>
<style scoped>
     #tabPartenerCard ul {
         list-style-type: none;
         margin: 0;
         padding: 0;
     }
     #tabPartenerCard li {
         margin: 10px 0 0 0;
     }

     label {
         display: inline-block;
         width: 300px;
         text-align: right;
     }
     
     input {
     	height: 10px;
     }

     .required {
         font-weight: bold;
     }

     .accept, .status {
         padding-left: 90px;
     }

     .valid {
         color: green;
     }

     .invalid {
         color: red;
     }
     span.k-tooltip {
         margin-left: 6px;
     }
 </style>



